(function () {
    class Animal{
        constructor(public name: string){
            this.name = name;
        }
    }
    class Dog extends Animal{
        constructor(name: string, public breed: string){
            super(name);
            this.breed = breed;
        }
    }
    const dog = new Dog('Max', 'Bernese Mountain Dog');
    console.log(dog.name); // 输出 "Max"
    console.log(dog.breed); // 输出 "Bernese Mountain Dog"
})()